#0,d,0

d.50.0.0d0 <- d.50.0                 
d.100.0.0d0 <- d.100.0
d.250.0.0d0 <- d.250.0
d.500.0.0d0 <- d.500.0
d.1000.0.0d0 <- d.1000.0
d.1500.0.0d0 <- d.1500.0

e.50.0.0d0 <- e.50.0             
e.100.0.0d0 <- e.100.0   
e.250.0.0d0 <- e.250.0 
e.500.0.0d0 <- e.500.0
e.1000.0.0d0 <- e.1000.0
e.1500.0.0d0 <- e.1500.0

#1,d,0

d.50.0.1d0 <- d.50.0                 
d.100.0.1d0 <- d.100.0
d.250.0.1d0 <- d.250.0
d.500.0.1d0 <- d.500.0
d.1000.0.1d0 <- d.1000.0
d.1500.0.1d0 <- d.1500.0

e.50.0.1d0 <- e.50.0             
e.100.0.1d0 <- e.100.0   
e.250.0.1d0 <- e.250.0 
e.500.0.1d0 <- e.500.0
e.1000.0.1d0 <- e.1000.0
e.1500.0.1d0 <- e.1500.0

#0,d,1

d.50.0.0d1 <- d.50.0                 
d.100.0.0d1 <- d.100.0
d.250.0.0d1 <- d.250.0
d.500.0.0d1 <- d.500.0
d.1000.0.0d1 <- d.1000.0
d.1500.0.0d1 <- d.1500.0

e.50.0.0d1 <- e.50.0             
e.100.0.0d1 <- e.100.0   
e.250.0.0d1 <- e.250.0 
e.500.0.0d1 <- e.500.0
e.1000.0.0d1 <- e.1000.0
e.1500.0.0d1 <- e.1500.0

#1,d,1

d.50.0.1d1 <- d.50.0                 
d.100.0.1d1 <- d.100.0
d.250.0.1d1 <- d.250.0
d.500.0.1d1 <- d.500.0
d.1000.0.1d1 <- d.1000.0
d.1500.0.1d1 <- d.1500.0

e.50.0.1d1 <- e.50.0             
e.100.0.1d1 <- e.100.0   
e.250.0.1d1 <- e.250.0 
e.500.0.1d1 <- e.500.0
e.1000.0.1d1 <- e.1000.0
e.1500.0.1d1 <- e.1500.0

##
## t
##

#0,d,0

t.50.0d0 <- d.50.0.0d0/e.50.0.0d0 
t.100.0d0 <- d.100.0.0d0/e.100.0.0d0 
t.250.0d0 <- d.250.0.0d0/e.250.0.0d0 
t.500.0d0 <- d.500.0.0d0/e.500.0.0d0 
t.1000.0d0 <- d.1000.0.0d0/e.1000.0.0d0 
t.1500.0d0 <- d.1500.0.0d0/e.1500.0.0d0 

rate.50.0d0 <- ((sum(ifelse(abs(t.50.0d0)>2.009,1,0))/100)*100)
rate.100.0d0 <- ((sum(ifelse(abs(t.100.0d0)>1.984,1,0))/100)*100)
rate.250.0d0 <- ((sum(ifelse(abs(t.250.0d0)>1.96,1,0))/100)*100)
rate.500.0d0 <- ((sum(ifelse(abs(t.500.0d0)>1.96,1,0))/100)*100)
rate.1000.0d0 <- ((sum(ifelse(abs(t.1000.0d0)>1.96,1,0))/100)*100)
rate.1500.0d0 <- ((sum(ifelse(abs(t.1500.0d0)>1.96,1,0))/100)*100)

#1,d,0

t.50.1d0 <- d.50.0.1d0/e.50.0.1d0 
t.100.1d0 <- d.100.0.1d0/e.100.0.1d0 
t.250.1d0 <- d.250.0.1d0/e.250.0.1d0 
t.500.1d0 <- d.500.0.1d0/e.500.0.1d0 
t.1000.1d0 <- d.1000.0.1d0/e.1000.0.1d0 
t.1500.1d0 <- d.1500.0.1d0/e.1500.0.1d0 

rate.50.1d0 <- ((sum(ifelse(abs(t.50.1d0)>2.009,1,0))/100)*100)
rate.100.1d0 <- ((sum(ifelse(abs(t.100.1d0)>1.984,1,0))/100)*100)
rate.250.1d0 <- ((sum(ifelse(abs(t.250.1d0)>1.96,1,0))/100)*100)
rate.500.1d0 <- ((sum(ifelse(abs(t.500.1d0)>1.96,1,0))/100)*100)
rate.1000.1d0 <- ((sum(ifelse(abs(t.1000.1d0)>1.96,1,0))/100)*100)
rate.1500.1d0 <- ((sum(ifelse(abs(t.1500.1d0)>1.96,1,0))/100)*100)

rate.50.1d0 
rate.100.1d0 
rate.250.1d0
rate.500.1d0 
rate.1000.1d0
rate.1500.1d0 

#0,d,1

t.50.0d1 <- d.50.0.0d1/e.50.0.0d1 
t.100.0d1 <- d.100.0.0d1/e.100.0.0d1 
t.250.0d1 <- d.250.0.0d1/e.250.0.0d1 
t.500.0d1 <- d.500.0.0d1/e.500.0.0d1 
t.1000.0d1 <- d.1000.0.0d1/e.1000.0.0d1 
t.1500.0d1 <- d.1500.0.0d1/e.1500.0.0d1 

rate.50.0d1 <- ((sum(ifelse(abs(t.50.0d1)>2.009,1,0))/100)*100)
rate.100.0d1 <- ((sum(ifelse(abs(t.100.0d1)>1.984,1,0))/100)*100)
rate.250.0d1 <- ((sum(ifelse(abs(t.250.0d1)>1.96,1,0))/100)*100)
rate.500.0d1 <- ((sum(ifelse(abs(t.500.0d1)>1.96,1,0))/100)*100)
rate.1000.0d1 <- ((sum(ifelse(abs(t.1000.0d1)>1.96,1,0))/100)*100)
rate.1500.0d1 <- ((sum(ifelse(abs(t.1500.0d1)>1.96,1,0))/100)*100)

rate.50.0d1 
rate.100.0d1 
rate.250.0d1
rate.500.0d1 
rate.1000.0d1
rate.1500.0d1 

#1,d,1

t.50.1d1 <- d.50.0.1d1/e.50.0.1d1 
t.100.1d1 <- d.100.0.1d1/e.100.0.1d1 
t.250.1d1 <- d.250.0.1d1/e.250.0.1d1 
t.500.1d1 <- d.500.0.1d1/e.500.0.1d1 
t.1000.1d1 <- d.1000.0.1d1/e.1000.0.1d1 
t.1500.1d1 <- d.1500.0.1d1/e.1500.0.1d1 

rate.50.1d1 <- ((sum(ifelse(abs(t.50.1d1)>2.009,1,0))/100)*100)
rate.100.1d1 <- ((sum(ifelse(abs(t.100.1d1)>1.984,1,0))/100)*100)
rate.250.1d1 <- ((sum(ifelse(abs(t.250.1d1)>1.96,1,0))/100)*100)
rate.500.1d1 <- ((sum(ifelse(abs(t.500.1d1)>1.96,1,0))/100)*100)
rate.1000.1d1 <- ((sum(ifelse(abs(t.1000.1d1)>1.96,1,0))/100)*100)
rate.1500.1d1 <- ((sum(ifelse(abs(t.1500.1d1)>1.96,1,0))/100)*100)

rate.50.1d1 
rate.100.1d1 
rate.250.1d1
rate.500.1d1 
rate.1000.1d1
rate.1500.1d1 


##
## Table Information
##


rate.50.0d0 
rate.100.0d0 
rate.250.0d0
rate.500.0d0 
rate.1000.0d0
rate.1500.0d0 

rate.50.1d0 
rate.100.1d0 
rate.250.1d0
rate.500.1d0 
rate.1000.1d0
rate.1500.1d0 

rate.50.0d1 
rate.100.0d1 
rate.250.0d1
rate.500.0d1 
rate.1000.0d1
rate.1500.0d1 

rate.50.1d1 
rate.100.1d1 
rate.250.1d1
rate.500.1d1 
rate.1000.1d1
rate.1500.1d1 

# Part #

rate.100.0d0 
rate.250.0d0
rate.1000.0d0

rate.100.1d0 
rate.250.1d0
rate.1000.1d0

rate.100.0d1 
rate.250.0d1
rate.1000.0d1

rate.100.1d1 
rate.250.1d1
rate.1000.1d1



summary(d.100.0.0d0)
summary(d.250.0.0d0)
summary(d.1000.0.0d0)

summary(d.100.0.1d0)
summary(d.250.0.1d0)
summary(d.1000.0.1d0)

summary(d.100.0.0d1)
summary(d.250.0.0d1)
summary(d.1000.0.0d1)

summary(d.100.0.1d1)
summary(d.250.0.1d1)
summary(d.1000.0.1d1)

##
## Toy Stuff
##


par(mfrow=c(1,1))
plot(density(t.1500.0d0))

rejrateLAGX <- mean(ifelse(abs(t.100.0d0)>1.96,1,0))
rate <- sum(ifelse(abs(t.100.0d0)>1.96,1,0))
